BIN=libcommon.ar
OBJ=errrep.o syntaxex.o tokmod.o rte.o stdex.o tokline.o tokmod.o stdafx.o
INCLUDE=-I.

all:${BIN}

${BIN}:${OBJ}
	ar -rcs ${BIN} ${OBJ}

errrep.o:errrep.cpp
	${CXX} ${CXXFLAGS} ${INCLUDE} -g -c -o errrep.o errrep.cpp

syntaxex.o:syntaxex.cpp
	${CXX} ${CXXFLAGS} ${INCLUDE} -g -c -o syntaxex.o syntaxex.cpp

tokmod.o:tokmod.cpp
	${CXX} ${CXXFLAGS} ${INCLUDE} -g -c -o tokmod.o tokmod.cpp

rte.o:rte.cpp
	${CXX} ${CXXFLAGS} ${INCLUDE} -g -c -o rte.o rte.cpp

stdex.o:stdex.cpp
	${CXX} ${CXXFLAGS} ${INCLUDE} -g -c -o stdex.o stdex.cpp

tokline.o:tokline.cpp
	${CXX} ${CXXFLAGS} ${INCLUDE} -g -c -o tokline.o tokline.cpp

tokmod.o:tokmod.cpp
	${CXX} ${CXXFLAGS} ${INCLUDE} -g -c -o tokmod.o tokmod.cpp

stdafx.o:stdafx.cpp
	${CXX} ${CXXFLAGS} ${INCLUDE} -g -c -o stdafx.o stdafx.cpp

clean:
	rm -f ${BIN}
	rm -f ${OBJ}
	rm -f *~